package OoDay03;

public class InterFaceDemo {
    public static void main(String[] args) {
        //Inter a=new Inter();//编译错误，接口不能被实例化
    }
}
//演示接口语法
interface Inter{
    abstract void show();
    void test();//接口中的方法默认为抽象方法，前面默认有abstract
    //void say(){}//编译错误，抽象方法不能有方法体
}
//演示接口的多实现
class InterImpl implements Inter{
    public void test(){

    }
    public void show(){

    }
}
interface Inter1{
    void show();
}
interface Inter2{
    void test();
}
abstract class Aoo{
    abstract void say();
}
class Boo extends Aoo implements Inter1,Inter2{
    public void show(){}
    public void test(){}
    void say(){}
}
//演示接口继承接口
interface Inter3{
    void show();
}
interface Inter4 extends Inter3{
    void test();
}
class Coo implements Inter4{
    public void test(){}
    public void show(){}
}